﻿using SqlSugar;
namespace IMES.Entity
{
    /// <summary>
    /// 
    ///</summary>
    [SugarTable("sauser")]
    public class User : BaseEntity
    {  
        /// <summary>
        /// 用户名 
        ///</summary>
         [SugarColumn(ColumnName="UserCode"    )]
         public string UserCode { get; set; }
        /// <summary>
        /// 姓名 
        ///</summary>
         [SugarColumn(ColumnName="UserName"    )]
         public string UserName { get; set; }
        /// <summary>
        /// 密码 
        ///</summary>
         [SugarColumn(ColumnName="Password"    )]
         public string Password { get; set; }
        /// <summary>
        /// 手机号 
        ///</summary>
         [SugarColumn(ColumnName="Mobile"    )]
         public string Mobile { get; set; }
        /// <summary>
        /// 可用状态 
        ///</summary>
         [SugarColumn(ColumnName="Usable"    )]
         public bool Usable { get; set; }
        /// <summary>
        /// 最后登录时间 
        ///</summary>
         [SugarColumn(ColumnName="LoginTime"    )]
         public string LoginTime { get; set; }
        /// <summary>
        /// 最后登录IP 
        ///</summary>
         [SugarColumn(ColumnName="LoginIP"    )]
         public string LoginIP { get; set; }
        /// <summary>
        /// 备注
        /// </summary>
        [SugarColumn(IsNullable = true, ColumnDescription = "备注", ColumnDataType = "nvarchar(max)")]
        public string? Remark { get; set; }
        /// <summary>
        /// 创建人
        /// </summary>
        [SugarColumn(ColumnName = "Creator", ColumnDescription = "创建人")]
        public string Creator { get; set; }
        /// <summary>
        /// 创建时间
        /// </summary>
        [SugarColumn(ColumnName = "CreateTime", ColumnDescription = "创建时间")]
        public DateTime CreateTime { get; set; }
        /// <summary>
        /// 角色列表
        /// </summary>
        [SugarColumn(IsIgnore = true)]
        public ICollection<Role> Roles { get; set; }
    }
}
